import Taro, { Component } from '@tarojs/taro'
import {View,Text} from '@tarojs/components'


export default class Clockk extends Component{
    constructor(props){
        super(props)
        this.state = {
            time:new Date()
        }
    }
    componentDidMount(){
      
    }
    componentWillUnmount(){

    }
    render(){
        const {time} = this.state
        return(
            <View>
                <Text>现在时间是:</Text>
                 <Text>{time.toLocaleTimeString()}</Text>
            </View>
        )
    }
}